import request from '../utils/request'
import { HttpMethod } from '../utils/http'


const groupName = 'beauty/productCollection'
export default {
  /**
   * 切换收藏
   */
  changeCollection (data) {
    return request({
      url: `/${groupName}/changeCollection`,
      method: HttpMethod.POST,
      data
    })
  },
  /**
   *
   */
  getByProductId (productId) {
    return request({
      url: `/${groupName}/${productId}`,
      method: HttpMethod.GET
    })
  },
  /**
   * 分页查询
   */
  list (current, size) {
    return request({
      url: `/${groupName}/list/${current}/${size}`,
      method: HttpMethod.GET
    })
  },
}
